
// MIT License
// 
// Copyright (c) 2009-2017 Luca Piccioni
// 
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including without limitation the rights
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
// copies of the Software, and to permit persons to whom the Software is
// furnished to do so, subject to the following conditions:
// 
// The above copyright notice and this permission notice shall be included in all
// copies or substantial portions of the Software.
// 
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
// SOFTWARE.
// 
// This file is automatically generated

#pragma warning disable 649, 1572, 1573

// ReSharper disable RedundantUsingDirective
using System;
using System.Diagnostics;
using System.Runtime.InteropServices;
using System.Security;
using System.Text;

using Khronos;

// ReSharper disable CheckNamespace
// ReSharper disable InconsistentNaming
// ReSharper disable JoinDeclarationAndInitializer

namespace OpenGL
{
	public partial class Gl
	{
		/// <summary>
		/// [GL] Value of GL_VERTEX_ARRAY_COUNT_EXT symbol.
		/// </summary>
		[RequiredByFeature("GL_EXT_vertex_array")]
		public const int VERTEX_ARRAY_COUNT_EXT = 0x807D;

		/// <summary>
		/// [GL] Value of GL_NORMAL_ARRAY_COUNT_EXT symbol.
		/// </summary>
		[RequiredByFeature("GL_EXT_vertex_array")]
		public const int NORMAL_ARRAY_COUNT_EXT = 0x8080;

		/// <summary>
		/// [GL] Value of GL_COLOR_ARRAY_COUNT_EXT symbol.
		/// </summary>
		[RequiredByFeature("GL_EXT_vertex_array")]
		public const int COLOR_ARRAY_COUNT_EXT = 0x8084;

		/// <summary>
		/// [GL] Value of GL_INDEX_ARRAY_COUNT_EXT symbol.
		/// </summary>
		[RequiredByFeature("GL_EXT_vertex_array")]
		public const int INDEX_ARRAY_COUNT_EXT = 0x8087;

		/// <summary>
		/// [GL] Value of GL_TEXTURE_COORD_ARRAY_COUNT_EXT symbol.
		/// </summary>
		[RequiredByFeature("GL_EXT_vertex_array")]
		public const int TEXTURE_COORD_ARRAY_COUNT_EXT = 0x808B;

		/// <summary>
		/// [GL] Value of GL_EDGE_FLAG_ARRAY_COUNT_EXT symbol.
		/// </summary>
		[RequiredByFeature("GL_EXT_vertex_array")]
		public const int EDGE_FLAG_ARRAY_COUNT_EXT = 0x808D;

		/// <summary>
		/// [GL] glColorPointerEXT: Binding for glColorPointerEXT.
		/// </summary>
		/// <param name="size">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="type">
		/// A <see cref="T:ColorPointerType"/>.
		/// </param>
		/// <param name="stride">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="count">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="pointer">
		/// A <see cref="T:IntPtr"/>.
		/// </param>
		[RequiredByFeature("GL_EXT_vertex_array")]
		public static void ColorPointerEXT(int size, ColorPointerType type, int stride, int count, IntPtr pointer)
		{
			Debug.Assert(Delegates.pglColorPointerEXT != null, "pglColorPointerEXT not implemented");
			Delegates.pglColorPointerEXT(size, (int)type, stride, count, pointer);
			LogCommand("glColorPointerEXT", null, size, type, stride, count, pointer			);
			DebugCheckErrors(null);
		}

		/// <summary>
		/// [GL] glColorPointerEXT: Binding for glColorPointerEXT.
		/// </summary>
		/// <param name="size">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="type">
		/// A <see cref="T:ColorPointerType"/>.
		/// </param>
		/// <param name="stride">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="count">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="pointer">
		/// A <see cref="T:object"/>.
		/// </param>
		[RequiredByFeature("GL_EXT_vertex_array")]
		public static void ColorPointerEXT(int size, ColorPointerType type, int stride, int count, object pointer)
		{
			GCHandle pin_pointer = GCHandle.Alloc(pointer, GCHandleType.Pinned);
			try {
				ColorPointerEXT(size, type, stride, count, pin_pointer.AddrOfPinnedObject());
			} finally {
				pin_pointer.Free();
			}
		}

		/// <summary>
		/// [GL] glEdgeFlagPointerEXT: Binding for glEdgeFlagPointerEXT.
		/// </summary>
		/// <param name="stride">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="count">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="pointer">
		/// A <see cref="T:byte[]"/>.
		/// </param>
		[RequiredByFeature("GL_EXT_vertex_array")]
		public static void EdgeFlagPointerEXT(int stride, int count, byte[] pointer)
		{
			unsafe {
				fixed (byte* p_pointer = pointer)
				{
					Debug.Assert(Delegates.pglEdgeFlagPointerEXT != null, "pglEdgeFlagPointerEXT not implemented");
					Delegates.pglEdgeFlagPointerEXT(stride, count, p_pointer);
					LogCommand("glEdgeFlagPointerEXT", null, stride, count, pointer					);
				}
			}
			DebugCheckErrors(null);
		}

		/// <summary>
		/// [GL] glIndexPointerEXT: Binding for glIndexPointerEXT.
		/// </summary>
		/// <param name="type">
		/// A <see cref="T:IndexPointerType"/>.
		/// </param>
		/// <param name="stride">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="count">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="pointer">
		/// A <see cref="T:IntPtr"/>.
		/// </param>
		[RequiredByFeature("GL_EXT_vertex_array")]
		public static void IndexPointerEXT(IndexPointerType type, int stride, int count, IntPtr pointer)
		{
			Debug.Assert(Delegates.pglIndexPointerEXT != null, "pglIndexPointerEXT not implemented");
			Delegates.pglIndexPointerEXT((int)type, stride, count, pointer);
			LogCommand("glIndexPointerEXT", null, type, stride, count, pointer			);
			DebugCheckErrors(null);
		}

		/// <summary>
		/// [GL] glIndexPointerEXT: Binding for glIndexPointerEXT.
		/// </summary>
		/// <param name="type">
		/// A <see cref="T:IndexPointerType"/>.
		/// </param>
		/// <param name="stride">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="count">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="pointer">
		/// A <see cref="T:object"/>.
		/// </param>
		[RequiredByFeature("GL_EXT_vertex_array")]
		public static void IndexPointerEXT(IndexPointerType type, int stride, int count, object pointer)
		{
			GCHandle pin_pointer = GCHandle.Alloc(pointer, GCHandleType.Pinned);
			try {
				IndexPointerEXT(type, stride, count, pin_pointer.AddrOfPinnedObject());
			} finally {
				pin_pointer.Free();
			}
		}

		/// <summary>
		/// [GL] glNormalPointerEXT: Binding for glNormalPointerEXT.
		/// </summary>
		/// <param name="type">
		/// A <see cref="T:NormalPointerType"/>.
		/// </param>
		/// <param name="stride">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="count">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="pointer">
		/// A <see cref="T:IntPtr"/>.
		/// </param>
		[RequiredByFeature("GL_EXT_vertex_array")]
		public static void NormalPointerEXT(NormalPointerType type, int stride, int count, IntPtr pointer)
		{
			Debug.Assert(Delegates.pglNormalPointerEXT != null, "pglNormalPointerEXT not implemented");
			Delegates.pglNormalPointerEXT((int)type, stride, count, pointer);
			LogCommand("glNormalPointerEXT", null, type, stride, count, pointer			);
			DebugCheckErrors(null);
		}

		/// <summary>
		/// [GL] glNormalPointerEXT: Binding for glNormalPointerEXT.
		/// </summary>
		/// <param name="type">
		/// A <see cref="T:NormalPointerType"/>.
		/// </param>
		/// <param name="stride">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="count">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="pointer">
		/// A <see cref="T:object"/>.
		/// </param>
		[RequiredByFeature("GL_EXT_vertex_array")]
		public static void NormalPointerEXT(NormalPointerType type, int stride, int count, object pointer)
		{
			GCHandle pin_pointer = GCHandle.Alloc(pointer, GCHandleType.Pinned);
			try {
				NormalPointerEXT(type, stride, count, pin_pointer.AddrOfPinnedObject());
			} finally {
				pin_pointer.Free();
			}
		}

		/// <summary>
		/// [GL] glTexCoordPointerEXT: Binding for glTexCoordPointerEXT.
		/// </summary>
		/// <param name="size">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="type">
		/// A <see cref="T:TexCoordPointerType"/>.
		/// </param>
		/// <param name="stride">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="count">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="pointer">
		/// A <see cref="T:IntPtr"/>.
		/// </param>
		[RequiredByFeature("GL_EXT_vertex_array")]
		public static void TexCoordPointerEXT(int size, TexCoordPointerType type, int stride, int count, IntPtr pointer)
		{
			Debug.Assert(Delegates.pglTexCoordPointerEXT != null, "pglTexCoordPointerEXT not implemented");
			Delegates.pglTexCoordPointerEXT(size, (int)type, stride, count, pointer);
			LogCommand("glTexCoordPointerEXT", null, size, type, stride, count, pointer			);
			DebugCheckErrors(null);
		}

		/// <summary>
		/// [GL] glTexCoordPointerEXT: Binding for glTexCoordPointerEXT.
		/// </summary>
		/// <param name="size">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="type">
		/// A <see cref="T:TexCoordPointerType"/>.
		/// </param>
		/// <param name="stride">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="count">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="pointer">
		/// A <see cref="T:object"/>.
		/// </param>
		[RequiredByFeature("GL_EXT_vertex_array")]
		public static void TexCoordPointerEXT(int size, TexCoordPointerType type, int stride, int count, object pointer)
		{
			GCHandle pin_pointer = GCHandle.Alloc(pointer, GCHandleType.Pinned);
			try {
				TexCoordPointerEXT(size, type, stride, count, pin_pointer.AddrOfPinnedObject());
			} finally {
				pin_pointer.Free();
			}
		}

		/// <summary>
		/// [GL] glVertexPointerEXT: Binding for glVertexPointerEXT.
		/// </summary>
		/// <param name="size">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="type">
		/// A <see cref="T:VertexPointerType"/>.
		/// </param>
		/// <param name="stride">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="count">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="pointer">
		/// A <see cref="T:IntPtr"/>.
		/// </param>
		[RequiredByFeature("GL_EXT_vertex_array")]
		public static void VertexPointerEXT(int size, VertexPointerType type, int stride, int count, IntPtr pointer)
		{
			Debug.Assert(Delegates.pglVertexPointerEXT != null, "pglVertexPointerEXT not implemented");
			Delegates.pglVertexPointerEXT(size, (int)type, stride, count, pointer);
			LogCommand("glVertexPointerEXT", null, size, type, stride, count, pointer			);
			DebugCheckErrors(null);
		}

		/// <summary>
		/// [GL] glVertexPointerEXT: Binding for glVertexPointerEXT.
		/// </summary>
		/// <param name="size">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="type">
		/// A <see cref="T:VertexPointerType"/>.
		/// </param>
		/// <param name="stride">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="count">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="pointer">
		/// A <see cref="T:object"/>.
		/// </param>
		[RequiredByFeature("GL_EXT_vertex_array")]
		public static void VertexPointerEXT(int size, VertexPointerType type, int stride, int count, object pointer)
		{
			GCHandle pin_pointer = GCHandle.Alloc(pointer, GCHandleType.Pinned);
			try {
				VertexPointerEXT(size, type, stride, count, pin_pointer.AddrOfPinnedObject());
			} finally {
				pin_pointer.Free();
			}
		}

		internal static unsafe partial class Delegates
		{
			[RequiredByFeature("GL_EXT_vertex_array")]
			[SuppressUnmanagedCodeSecurity]
			internal delegate void glColorPointerEXT(int size, int type, int stride, int count, IntPtr pointer);

			[RequiredByFeature("GL_EXT_vertex_array")]
			[ThreadStatic]
			internal static glColorPointerEXT pglColorPointerEXT;

			[RequiredByFeature("GL_EXT_vertex_array")]
			[SuppressUnmanagedCodeSecurity]
			internal delegate void glEdgeFlagPointerEXT(int stride, int count, byte* pointer);

			[RequiredByFeature("GL_EXT_vertex_array")]
			[ThreadStatic]
			internal static glEdgeFlagPointerEXT pglEdgeFlagPointerEXT;

			[RequiredByFeature("GL_EXT_vertex_array")]
			[SuppressUnmanagedCodeSecurity]
			internal delegate void glIndexPointerEXT(int type, int stride, int count, IntPtr pointer);

			[RequiredByFeature("GL_EXT_vertex_array")]
			[ThreadStatic]
			internal static glIndexPointerEXT pglIndexPointerEXT;

			[RequiredByFeature("GL_EXT_vertex_array")]
			[SuppressUnmanagedCodeSecurity]
			internal delegate void glNormalPointerEXT(int type, int stride, int count, IntPtr pointer);

			[RequiredByFeature("GL_EXT_vertex_array")]
			[ThreadStatic]
			internal static glNormalPointerEXT pglNormalPointerEXT;

			[RequiredByFeature("GL_EXT_vertex_array")]
			[SuppressUnmanagedCodeSecurity]
			internal delegate void glTexCoordPointerEXT(int size, int type, int stride, int count, IntPtr pointer);

			[RequiredByFeature("GL_EXT_vertex_array")]
			[ThreadStatic]
			internal static glTexCoordPointerEXT pglTexCoordPointerEXT;

			[RequiredByFeature("GL_EXT_vertex_array")]
			[SuppressUnmanagedCodeSecurity]
			internal delegate void glVertexPointerEXT(int size, int type, int stride, int count, IntPtr pointer);

			[RequiredByFeature("GL_EXT_vertex_array")]
			[ThreadStatic]
			internal static glVertexPointerEXT pglVertexPointerEXT;

		}
	}

}
